<template>

	<view>

		<view style="padding: 20upx 0upx; text-align: center;background-color: #E93B3D;margin-bottom: 30upx;color: #FFFFFF;">
			<view>账户余额（元）</view>
			<view style="font-size: 60upx;margin-top: 20upx;margin-bottom: 10upx;">{{userInfo.BalanceProfits}}</view>
		</view>


		<block v-for="(item, index) in info" :key="item._id">

			<view style="width: 750upx;display: block;">
				<view style="width: 730upx;padding: 10upx 10upx 40upx 10upx;">
					<view style="width: 360upx;float: left;">增加:<label style="color: #FA436A;">￥{{item.DistAmount}}</label> </view>
					<view style="width: 350upx;float: right;">{{item.OdrTimeStr}}</view>
				</view>

				<view style="width: 710upx;float: left;margin: 10upx 10upx 40upx 10upx;border: 1upx solid #909399;padding: 20upx;background-color: #FFFFFF;">
					【{{item.BuyMemLevName}}】-【{{item.BuyMemNick}}】购买的【{{item.ProName}} * {{item.ProNums}}】{{item.DistMemo}}。
				</view>
			</view>

		</block>








	</view>

</template>

<script>
	import {
		mapState
	} from 'vuex';

	export default {
		data() {
			return {

				info: []


			};
		},
		computed: {
			...mapState(['token', 'exp_time', 'hasLogin', 'userInfo'])
		},
		onLoad() {





			uni.request({
				url: this.$serverUrl + `/app/profit/query/` + this.userInfo.MemId,
				header: {
					"Content-Type": "application/json",
					"Authorization": this.token
				},
				data: {
					"page_index": 1,
					"page_size": 1000
				},
				method: "POST",
				success: (e) => {
					if (e.data.success) {
						this.info = e.data.rows


					} else {
						console.log(e.data.message)
					}
				},
				fail: (e) => {
					console.log(e.errMsg)
				}
			})

















		}
	}
</script>


<style lang="scss">
	page {
		background: $page-color-base;
	}
	
	.flas {

		float: left;
		width: 200upx;

	}
</style>
